package com.clqteam.serviceimpl;

import java.util.List;

import com.clqteam.dao.serachProductByInfoDao;
import com.clqteam.daoimpl.serachProductByInfoDaoImpl;
import com.clqteam.model.Product;
import com.clqteam.service.serachProductByInfoService;

import net.sf.json.JSONObject;

public class serachProductByInfoServiceImpl implements serachProductByInfoService{
	
	serachProductByInfoDao spb = new serachProductByInfoDaoImpl();

	@Override
	public JSONObject findProductByInfo(String searType, String sertInfo,int page,int rows) {
		JSONObject j = new JSONObject();
		j.put("total",spb.serachProductCountByInfo(searType, sertInfo));
		j.put("rows",spb.serachProductByInfo(searType, sertInfo, page, rows));
		return j;
	}

}
